package com.linewell.entity;

import javax.validation.constraints.Pattern;
import java.util.Date;

public class UserInfo {
	
    private Long userId;
    @Pattern(regexp = "(^[a-zA-Z0-9_-]{6,16}$)|([\u2E80-\u9FFF]{2,5})"
			,message="用户名必须的6-16位的数字字母组合或2-5位中文")
    private String punsterName;

    private String pwd;

    private String nickName;

    private String sex;

    private String picture;

    private int focusNum;

    private int fansNum;

    private Date birthday;
    @Pattern(regexp = "(^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\\.[a-zA-Z0-9_-]+)+$)"
            ,message = "邮箱格式为英文字母、数字、下划线、英文句号、以及中划线组成")
    private String email;

    private String myEvaluation;

    /**
     *  0为正常  1为封号
     */
    private int state;

    public int getState() {
        return state;
    }

    public void setState(int state) {
        this.state = state;
    }

    public Date getBirthday() {
        return birthday;
    }

    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getMyEvaluation() {
        return myEvaluation;
    }

    public void setMyEvaluation(String myEvaluation) {
        this.myEvaluation = myEvaluation;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getPunsterName() {
        return punsterName;
    }

    public void setPunsterName(String punstername) {
        this.punsterName = punstername == null ? null : punstername.trim();
    }

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd == null ? null : pwd.trim();
    }

    public String getNickName() {
        return nickName;
    }

    public void setNickName(String nickname) {
        this.nickName = nickname == null ? null : nickname.trim();
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex == null ? null : sex.trim();
    }

    public String getPicture() {
        return picture;
    }

    public void setPicture(String picture) {
        this.picture = picture == null ? null : picture.trim();
    }

    public int getFocusNum() {
        return focusNum;
    }

    public void setFocusNum(int focusNum) {
        this.focusNum = focusNum;
    }

    public int getFansNum() {
        return fansNum;
    }

    public void setFansNum(int fansNum) {
        this.fansNum = fansNum;
    }

    @Override
    public String toString() {
        return "UserInfo{" +
                "userId=" + userId +
                ", punsterName='" + punsterName + '\'' +
                ", pwd='" + pwd + '\'' +
                ", nickName='" + nickName + '\'' +
                ", sex='" + sex + '\'' +
                ", picture='" + picture + '\'' +
                ", focusNum='" + focusNum + '\'' +
                ", fansNum='" + fansNum + '\'' +
                '}';
    }
}